<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        //  flat实例方法   拉平数组 
        //  会把数组成员中嵌套数组 的成员取出来 生成一个新的数组
        let arr = [[3,5],[7,8],[9,10],[11,12]];
        let arr1 = arr.flat();
        console.log(arr,arr1);

        let arr2 = [3,4,5,[6,7],[9,[10,11]]];
        console.log(arr2,arr2.flat(2));
    </script>
</body>
</html>